import { defineStore } from 'pinia'
import { ref } from 'vue'

export const useCleaningStore = defineStore(
  'cleaning',
  () => {
    // 设施清单
    const facilityList = ref([])
    const roomName = ref('')

    const setFacilityList = (newVal) => {
      facilityList.value = newVal
    }

    const setRoomName = (newVal) => {
      roomName.value = newVal
    }

    return {
      facilityList,
      setFacilityList,
      roomName,
      setRoomName,
    }
  },
  {
    persist: true,
  },
)
